import { useRoute } from 'vue-router'

import { bus } from '@/utils'

export function useToolbar() {
  const route = useRoute()

  function handleClose() {
    bus.emit('handleCloseTab', route)
  }

  return {
    handleClose
  }
}
